#if !defined(ximera_physics_ientity_hpp)
#define ximera_physics_ientity_hpp

// -----------------------------------------------------------

#include <ximera/physics/irigidbody.hpp>
#include <ximera/physics/ishape.hpp>

namespace ximera { namespace physics
{
    class ISpace;

    XIMERA_ENUM(EntityType)
        Dynamic,
        Static
    XIMERA_ENUM_END(EntityType)

    class XIMERA_API IEntity
    {
    public:
		virtual ~IEntity();

        virtual EntityType type() const = 0;

        virtual ISpace* space() const = 0;

        virtual IRigidBody* body() const = 0;

        virtual UInt32 shapeCount() const = 0;
        virtual IShape* shape(UInt32 index) const = 0;

        virtual void addShape(IShape* shape) = 0;
        virtual void removeShape(IShape* shape) = 0;
        virtual void removeAllShapes() = 0;

        virtual IShape* createShape(ShapeType type) = 0;

        template <typename T>
        T* createShape();
    };
}}

#include <ximera/physics/inline/ientity.inl>

// -----------------------------------------------------------

#endif
